import { defineStore } from "pinia";
import img1 from "../assets/1.jpg?url";
import img2 from "../assets/2.jpg?url";
import img3 from "../assets/3.jpg?url";
import type { ITea } from "../types/ITea.ts";

interface State {
  teaList: ITea[];
}

export const useTeaStore = defineStore("teas", {
    state: (): State => ({
      teaList: [
        { id: 1, title: "杭州龙井", description: "鲜爽口感, 淡雅香气", imgSrc: img1, price: 30 },
        { id: 2, title: "黄山毛峰", description: "色泽嫩黄, 茶汤清澈", imgSrc: img2, price: 50 },
        { id: 3, title: "苏州碧螺春", description: "测试", imgSrc: img2, price: 40 },
        { id: 4, title: "安溪铁观音", description: "测试", imgSrc: img2, price: 50 },
        { id: 5, title: "庐山云雾", description: "测试", imgSrc: img2, price: 10 },
        { id: 6, title: "白毫银针", description: "测试", imgSrc: img2, price: 60 },
        { id: 7, title: "武夷岩茶", description: "测试", imgSrc: img2, price: 80 },
        {
          id: 8,
          title: "普洱茶",
          description: "普洱茶以其浓厚的口感和独特的陈香著称。其茶叶经过发酵处理, 色泽褐红, 茶汤深沉, 具有独特的醇厚滋味和健康功效。",
          imgSrc: img3,
          price: 70
        }
      ]
    }),
    actions: {}
  })
;